#include<iostream>
#include<unistd.h>
#include<sys/signal.h>
void sigcb(int signo)
{
    std::cout << "signo: " << signo << std::endl;
}
int main()
{
    while(true)
    {
        signal(SIGINT, sigcb);
        std::cout << "hello" << std::endl;
        sleep(1);
    }
    return 0;
}